package com.lei.service.impl;

import com.lei.dao.MenuDao;
import com.lei.dao.impl.MenuDaoImpl;
import com.lei.entity.Menu;
import com.lei.service.MenuService;

import java.util.List;

/**
 * @author Lei Chu
 * @Date 2020/10/16 20:54
 */
public class MenuServiceImpl implements MenuService {

    private MenuDao menuDao = new MenuDaoImpl();

    @Override
    public List<Menu> getAllMenuByRid(Integer rid) {
        return menuDao.getAllMenuByRid(rid);
    }

    @Override
    public List<Menu> getAllMenu() {
        return menuDao.getAllMenu();
    }

    @Override
    public List<Integer> getMenuByRid(String rid) {
        return menuDao.getMenuByRid(rid);
    }

    @Override
    public String updateRoleMenu(String rid, String[] mids) {
        return menuDao.updateRoleMenu(rid,mids);
    }
}
